package com.ruoyi.manage.cms.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.common.utils.ListUtil;
import com.ruoyi.manage.cms.domain.GovernmentInfo;
import com.ruoyi.manage.cms.mapper.GovernmentInfoMapper;
import com.ruoyi.manage.cms.service.IGovernmentInfoService;
import org.springframework.stereotype.Service;


/**
 * 政府部门管理Service业务层处理
 *
 * @author ruoyi
 * @date 2025-07-27
 */
@Service
public class GovernmentInfoServiceImpl extends ServiceImpl<GovernmentInfoMapper, GovernmentInfo> implements IGovernmentInfoService{


    @Override
    public GovernmentInfo queryGetById(String id){
        GovernmentInfo governmentInfo = this.getById(id);
        return governmentInfo;
    }

    /**
     * 新增政府部门管理
     *
     * @param governmentInfo 政府部门管理
     * @return 结果
     */
    @Override
    public boolean addGovernmentInfo(GovernmentInfo governmentInfo){
        boolean save =this.save(governmentInfo);
        return save;
    }

    /**
     * 修改政府部门管理
     *
     * @param governmentInfo 政府部门管理
     * @return 结果
     */
    @Override
    public boolean updateGovernmentInfo(GovernmentInfo governmentInfo){
        return this.updateById(governmentInfo);
    }

    /**
     * 批量删除政府部门管理
     *
     * @param ids 需要删除的政府部门管理主键
     * @return 结果
     */
    @Override
    public boolean deleteGovernmentInfoByIds(String[] ids){
        return this.removeByIds(ListUtil.toList(ids));
    }

}
